import request from '@/utils/request'

// 删除文件
export function deleteFile(path) {
  return request({
    url: 'trial-file/infra/file/delete?path=' + path,
    method: 'delete'
  })
}

// 获得文件分页
export function getFilePage(query) {
  return request({
    url: 'trial-file/infra/file/page',
    method: 'get',
    params: query
  })
}

// 文件下载
export function downloadFile(id,path){
  return request({
    url: 'trial-file/infra/file/' + id + '/get/' + path,
    method: 'get',
    responseType: 'blob'
  })
}